<?php

namespace app\api\validate\meet;

use think\Validate;

class Join extends Validate
{
    /**
     * 验证规则
     */
    protected $rule = [
        'province_id' => 'require',
        'city_id' => 'require',
        'area_id' => 'require',
        'name' => 'require',
        'mobile' => 'require|regex:^1\d{10}$',
    ];
    /**
     * 提示消息
     */
    protected $message = [
        'province_id.require' => 'Please select a province or city',
        'city_id.require' => 'Please select a province or city',
        'area_id.require' => 'Please select a province or city',
        'name.require' => 'Name cannot be empty',
        'mobile.require' => 'Mobile phone number cannot be empty',
        'mobile.regex' => 'Mobile number format error',
    ];
    /**
     * 验证场景
     */
    protected $scene = [
        'add' => [],
        'edit' => [],
    ];

}
